package com.cheng.sell.service;

import com.cheng.sell.dto.OrderMasterDTO;
import com.cheng.sell.entity.OrderMaster;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;

/**
 * <p>
 * Description:
 * </p>
 *
 * @author chengxintao
 * @version 1.0
 * <p>
 * <p>
 * History:
 * <p>
 * Date                 Author         Version     Description
 * ---------------------------------------------------------------------------------
 * 2018/8/24         chengxintao          1.0         To create
 * </p>
 * @see
 * @since
 */
public interface OrderMasterService {

    /**
     * 创建订单 .
     */
    OrderMasterDTO create(OrderMasterDTO orderMasterDTO);

    /**
     * 取消订单 .
     */
    OrderMasterDTO cancel(OrderMasterDTO orderMasterDTO);

    /**
     * 完结订单 .
     */
    OrderMasterDTO end(OrderMasterDTO orderMasterDTO);

    /**
     * 支付订单 .
     */
    OrderMasterDTO paid(OrderMasterDTO orderMasterDTO);

    /**
     * 查询单个订单 .
     */
    OrderMasterDTO query(String orderId);

    /**
     * 查询订单列表 .
     */
    Page<OrderMasterDTO> findByBuyerOpenid(String buyerOpenid, Pageable pageable);
}
